package com.zhangtai.modules.vo;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.zhangtai.config.LongJsonDeserializer;
import com.zhangtai.config.LongJsonSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;

import javax.validation.constraints.NotNull;
import java.util.List;

@Data
public class MailVo {

    @ApiModelProperty(value="收件人",required = true)
    @NotNull(message = "收件人不能为空")
    String receive;

    @ApiModelProperty(value="主题",required = true)
    @NotNull(message = "标题不能为空")
    String subject;
    @ApiModelProperty(value="正文",required = false)
    String content;
    @ApiModelProperty(value="附件url集合",required = false)
    List<String> url;

    @ApiModelProperty(value="员工id",required = true)
    @NotNull(message = "员工id不能为空")
    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    Long oid;
    /**
     *  0:offer,1:签约邮件
     */
    private Integer type;

    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    private Long sendOid;

}
